<!DOCTYPE html>
<head>
	<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
	<title>后台管理</title>
	<link rel="shortcut icon" type="image/ico" href="/images/favicon.ico">
	<link href="/css/admin/style.css" rel="stylesheet" type="text/css" />
	<link href="/css/validator.css" rel="stylesheet" type="text/css" />
	<script src="/js/jquery-1.4.4.js" type="text/javascript" charset="UTF-8"></script>
	<script src="/js/formValidator-4.1.1.js" type="text/javascript" charset="UTF-8"></script>
	<script src="/js/formValidatorRegex.js" type="text/javascript" charset="UTF-8"></script>
	<script type="text/javascript" src="/js/admin.js"></script>
	
	<script>
	$(document).ready(function(){
		$.formValidator.initConfig({formID:"form1",autoTip:true,tidyMode:true,onError:function(msg){}});
		
	    $("#name").formValidator({onShow:"请输入栏目名称",onFocus:"至少2个字符",onCorrect:"输入正确"}).inputValidator({min:2,max:200,onError:"输入不合法，请确认"});
	    $("#pathKey").formValidator({onShow:"请输入路径KEY",onFocus:"2-10个字符",onCorrect:"输入正确"}).inputValidator({min:2,max:10,onError:"输入不合法，请确认"});
	    $("#path").formValidator({onShow:"请输入栏目路径",onFocus:"至少2个字符",onCorrect:"输入正确"}).inputValidator({min:2,max:200,onError:"输入不合法，请确认"});
	    $("#title").formValidator({onShow:"请输入title",onFocus:"至少2个字符",onCorrect:"输入正确"}).inputValidator({min:2,max:50,onError:"输入不合法，请确认2-50"});
	    $("#keywords").formValidator({onShow:"请输入keywords",onFocus:"至少2个字符",onCorrect:"输入正确"}).inputValidator({min:2,max:200,onError:"输入不合法，请确认"});
	    $("#description").formValidator({onShow:"请输入description",onFocus:"至少2个字符",onCorrect:"输入正确"}).inputValidator({min:2,max:200,onError:"输入不合法，请确认"});
	});
	</script>
</head>

<body>
	
		<#include "/admin/nav.ftl">
		
		<div id="wrapper">
			<div id="nav_trail"><a href="#">后台管理</a> 管理首页</div>
			<div id="content">
			
				<!-- 左边菜单 -->
				<#include "/admin/left_menu.ftl">
				<!-- 左边菜单 -->
				
				<script>
					menusel('m_item');
				</script>
	
	
				<div class="right_area">
					<div class="cbar">
			            
			              <ul>
			                <li ><a href="/admin/item/index">栏目列表</a></li>
			    			<li class="cbar-tag-sel">栏目编辑</li>
			              </ul>
			         </div><!-- cbar end -->
			         
			         <div class="cbox">
          
            <div class="ydbar">
      			<div class="info-title">栏目编辑</div>
    		</div>	
       		
       		<form id="form1" name="form1" method="post" action="/admin/item/update">
		         <input type="hidden" name="state" value="1"/>
		    <table cellspacing="0" cellpadding="0" border="0" class="table-f">
		      <tbody>
		      
		      <input type="hidden" name="id" value="${item.id}"/>
		      <tr>
		        <td align="right" width="15%" class="formtdl">栏目名称：</td>
		        <td align="left" colspan="3"><input type="text" id="name" size="30" name="name" class="fl" value="${item.name?default("")}">
		        <div id="nameTip" class="onShow tips" style="width:200px;">请输入栏目名称</div></td>
		      </tr>
		      <tr>
		        <td align="right" width="15%" class="formtdl">路径KEY：</td>
		        <td align="left" colspan="3"><input type="text" id="pathKey" size="30" name="pathKey" class="fl" value="${item.pathKey?default("")}">
		        <div id="pathKeyTip" class="onShow tips" style="width:200px;">请输入列表路径</div></td>
		      </tr>
		      <tr>
		        <td align="right" width="15%" class="formtdl">列表路径：</td>
		        <td align="left" colspan="3"><input type="text" id="path" size="30" name="path" class="fl" value="${item.path?default("")}">
		        <div id="pathTip" class="onShow tips" style="width:200px;">请输入列表路径</div></td>
		      </tr>
		      <tr>
		        <td align="right" width="15%" class="formtdl">title：</td>
		        <td align="left" colspan="3"><input type="text" id="title" size="70" name="title" value="${item.title?default("")}" class="fl">
		        <div id="titleTip" class="onShow tips" style="width:200px;">请输入title</div></td>
		      </tr>
		      <tr>
		        <td align="right" width="15%" class="formtdl">keywords：</td>
		        <td align="left" colspan="3"><input type="text" id="keywords" size="70" name="keywords" value="${item.keywords?default("")}" class="fl">
		        <div id="keywordsTip" class="onShow tips" style="width:200px;">请输入keywords,多个用英文,号分隔</div></td>
		      </tr>
		     <tr>
		        <td align="right" width="15%" class="formtdl">description：</td>
		        <td align="left" colspan="3"><textarea id="description" name="description" cols="80" rows="5" class="fl">${item.description?default("")}</textarea>
		        <div id="descriptionTip" class="onShow tips" style="width:200px;">请输入description</div></td>
		      </tr>
		      
		    </tbody></table>
		    
    
		    <table width="100%" cellspacing="0" cellpadding="0" border="0">
		      <tbody><tr>
		          <td align="center">
		            <input type="submit" value="提交" id="button" class="inp-yd" name="button">
		            
		        </td></tr>
		    </tbody></table>
		  </form>
             
          </div><!-- cbox end -->
            
			            
			        </div><!-- right_area end -->
				</div>
				
				<div class="clear"></div>
			</div> <!-- content end-->
			<div id="footer"></div>
   		</div><!-- wrapper end-->
</body>
</html>